package cn.stylefeng.guns.modular.bms.mapper;

import cn.stylefeng.guns.modular.bms.entity.City;
import cn.stylefeng.guns.modular.bms.model.params.CityParam;
import cn.stylefeng.guns.modular.bms.model.result.CityResult;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 城市信息 Mapper 接口
 * </p>
 *
 * @author yzb
 * @since 2022-05-24
 */
public interface CityMapper extends BaseMapper<City> {


    /**
     * 查询单条数据，Specification模式
     *
     */
    CityResult findBySpec(@Param("paramCondition") CityParam paramCondition);

    /**
     * 获取列表
     *
     *
     * @author yzb
     * @Date 2022-05-24
     */
    List<CityResult> customList(@Param("paramCondition") CityParam paramCondition);


    /**
     * 获取直辖市列表
     *
     *
     * @author yzb
     * @Date 2022-05-24
     */
    List<CityResult> getZhiXiaShiList(@Param("paramCondition") CityParam paramCondition);



    /**
     * 获取map列表
     *
     * @author yzb
     * @Date 2022-05-24
     */
    List<Map<String, Object>> customMapList(@Param("paramCondition") CityParam paramCondition);

    /**
     * 获取分页实体列表
     *
     * @author yzb
     * @Date 2022-05-24
     */
    Page<CityResult> customPageList(@Param("page") Page page, @Param("paramCondition") CityParam paramCondition);

    /**
     * 获取分页map列表
     *
     * @author yzb
     * @Date 2022-05-24
     */
    Page<Map<String, Object>> customPageMapList(@Param("page") Page page, @Param("paramCondition") CityParam paramCondition);

}
